// This file is deprecated. Use repair-workflow.model.ts instead.
// Keeping for backward compatibility temporarily.

export interface Device {
  id: number;
  name: string;
  serialNumber: string;
  model: string;
  location: string;
  status: DeviceStatus;
  createdAt: Date;
  lastMaintenanceDate?: Date;
}

export enum DeviceStatus {
  Normal = 'Normal',
  NeedsMaintenance = 'NeedsMaintenance',
  UnderRepair = 'UnderRepair',
  OutOfService = 'OutOfService'
}

export interface RepairRequest {
  id: number;
  deviceId: number;
  device?: Device;
  title: string;
  description: string;
  priority: RepairPriority;
  status: RepairStatus;
  requestedBy: string;
  assignedTo?: string;
  createdAt: Date;
  startedAt?: Date;
  completedAt?: Date;
  workflowInstanceId?: string;
  notes?: string;
  estimatedCost?: number;
  actualCost?: number;
}

export enum RepairPriority {
  Low = 1,
  Medium = 2,
  High = 3,
  Critical = 4
}

export enum RepairStatus {
  Pending = 'Pending',
  DecisionPending = 'DecisionPending',
  ExternalRepair = 'ExternalRepair',
  InternalRepair = 'InternalRepair',
  WaitingForApproval = 'WaitingForApproval',
  Approved = 'Approved',
  InProgress = 'InProgress',
  WaitingForParts = 'WaitingForParts',
  Testing = 'Testing',
  Completed = 'Completed',
  Rejected = 'Rejected',
  Cancelled = 'Cancelled'
} 